package com.dingding.order.core.common.rule.sql;

/**
 * 
 * @ClassName: ValuationRuleSQL 
 * @Description: 计价规则SQL类
 * @author YHQ
 * @date 2016年12月7日 下午2:56:58
 * @since V2.5.7
 * 
 */
public class ValuationRuleSQL {

	/**
	 * @author YHQ
	 * @Description: 获取计价规则列表
	 */
	public static final String GET_CHARGE_RULE_LIST = "SELECT cr.chargeRuleId, cr.cityId, cr.vehicleLevelId, cr.durationFee, cr.mileageFee, cr.minimums, cr.longStartMileage, cr.longFee, cr.nightFee, cr.nightStart, cr.nightEnd, cr.status,vl.vehicleLevel FROM dd_charge_rule cr INNER JOIN dd_vehicle_level vl ON cr.vehicleLevelId = vl.vehicleLevelId WHERE cr.cityId = ? AND cr.status = 1 AND vl.vehicleLevelStatus = 1";
	
	/**
	 * @author YHQ
	 * @Description: 根据车辆类型Id获取计价规则
	 */
	public static final String GET_CHARGE_RULE_BY_VEHICLE_ID = "SELECT cr.chargeRuleId, cr.cityId, cr.vehicleLevelId, cr.durationFee, cr.mileageFee, cr.minimums, cr.longStartMileage, cr.longFee, cr.nightFee, cr.nightStart, cr.nightEnd, cr.status,vl.vehicleLevel FROM dd_charge_rule cr INNER JOIN dd_vehicle_level vl ON cr.vehicleLevelId = vl.vehicleLevelId WHERE cr.vehicleLevelId = ? AND cr.status = 1 AND vl.vehicleLevelStatus = 1";
	
}
